from flask import Flask
from flask import render_template
import requests

app=Flask(__name__)

@app.route('/')
def index():
    headers = {'user-agent': 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/65.0.3325.162 Safari/537.36'}
    r=requests.get('https://huoxing.io/Api/marketDetailList',headers=headers)
    return render_template('index.html',data=r.json())

if __name__=='__main__':
    app.debug=False
    app.run(host="0.0.0.0",port=9000)
